
import request from '@/utils/request'


/**
 * @description 获取协议 列表
 * @param data
 */
export function getAgreementList() {
    var url = `setting/agreement`
    return request({url: url, method: 'get'})
}

/**
 * @description 获取协议
 * @param data
 */
export function getAgreements(type) {
    var url = `setting/agreement/get_agreement`

    return request({
        url: url,
        method: 'get',
        params:{'type':type}
    })
}


/**
 * @description 设置隐私协议
 * @param data
 */
export function setAgreements(data, type) {
    return request({
        url: `setting/agreement/save_agreement`,
        method: 'put',
        data,
    });
}
